package a66weding.com.jiehuntong.beans;


/**
 * 保存请求出错时，服务器端返回的结果数据
 */
public class ErrorBean {
    public static final int NONET=1;//网络失败
    public static final int TIMEOUT=2;//请求超时
    public static final int DATAERROR=3;//数据错误
    public static final int TRTANCETYPEERR=4;//类型转换错误

    protected String error_code;
    protected String error_msg;// 错误信息
    protected String requestCode;
    protected int errorCode;

    public ErrorBean() {
    }

    public ErrorBean(String error_code, String error_msg, String requestCode) {
        this.error_code = error_code;
        this.error_msg = error_msg;
        this.requestCode = requestCode;
    }

    public ErrorBean(int errorCode, String error_msg, String requestCode) {
        this.errorCode = errorCode;
        this.error_msg = error_msg;
        this.requestCode = requestCode;
    }

    public String getInf() {
        return requestCode;
    }

    public void setInf(String requestCode) {
        this.requestCode = requestCode;
    }

    public String getError_code() {
        return error_code;
    }

    public void setError_code(String error_code) {
        this.error_code = error_code;
    }

    public String getError_msg() {
        return error_msg;
    }

    public void setError_msg(String error_msg) {
        this.error_msg = error_msg;
    }

    public int getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(int errorCode) {
        this.errorCode = errorCode;
    }

    public static int getNONET() {
        return NONET;
    }

    public static int getTIMEOUT() {
        return TIMEOUT;
    }

    public static int getDATAERROR() {
        return DATAERROR;
    }

    public String getRequestCode() {
        return requestCode;
    }

    public void setRequestCode(String requestCode) {
        this.requestCode = requestCode;
    }

    @Override
    public String toString() {
        return "ErrorBean{" +
                "error_code='" + error_code + '\'' +
                ", error_msg='" + error_msg + '\'' +
                ", requestCode='" + requestCode + '\'' +
                ", errorCode=" + errorCode +
                '}';
    }
}
